import BaseApi from "../base.api";

export class WorkshopElementsInstanceApi extends BaseApi {
    protected baseUri = "/backend/workshop/workshop-elements-instances";

    save(data?: any) {
        return this.request.post(`${this.baseUri}`, data);
    }

    queryById(id: any) {
        return this.request.get(`${this.baseUri}/${id}`);
    }

    updateById(data: any) {
        return this.request.put(`${this.baseUri}`, data);
    }

    deleteByIds(ids: any){
        return this.request.delete(`${this.baseUri}/ids/${ids}`);
    }

    deleteById(id: any) {
        return this.request.delete(`${this.baseUri}/${id}`);
    }

    queryTree() {
        return this.request.get(`${this.baseUri}/tree`);
    }
}
